package CollegeInformation;

public class Employee {
    public String id;
    public String name;
    public String sex;
    public int age;
    public String type;

public Employee(){};


    @Override
    public String toString() {
        return
                "id='" + id + '\'' +
                ", name='" + name + '\'' +
                ", sex='" + sex + '\'' +
                ", age=" + age;
    }

    public Employee(String id, String name, String sex, int age, String type) {
        this.id = id;
        this.name = name;
        this.sex = sex;
        this.age = age;
        this.type = type;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }
}

class Teacher extends Employee{
    public String department;
    public String major;
    public String title;

    public Teacher(String id, String name, String sex, int age, String type, String department, String major, String title) {
        super(id, name, sex, age, type);
        this.department = department;
        this.major = major;
        this.title = title;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public String getMajor() {
        return major;
    }

    public void setMajor(String major) {
        this.major = major;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    @Override
    public String toString() {
        return "教师:" +
                "编号:" + id  +
                ", 姓名：" + name +
                ", 性别：" + sex  +
                ", 年龄：" + age +
                ", 所在系：" + department +
                ", 专业：" + major  +
                ", 职称：" + title ;
    }
}

class LabMember extends Employee{
    public String lab;
    public String job;

    public LabMember(String id, String name, String sex, int age, String type, String lab, String job) {
        super(id, name, sex, age, type);
        this.lab = lab;
        this.job = job;
    }

    public String getLab() {
        return lab;
    }

    public void setLab(String lab) {
        this.lab = lab;
    }

    public String getJob() {
        return job;
    }

    public void setJob(String job) {
        this.job = job;
    }

    @Override
    public String toString() {
        return "实验员:" +
                "编号:" + id  +
                ", 姓名：" + name +
                ", 性别：" + sex  +
                ", 年龄：" + age +
                ", 所在实验室：" + lab +
                ", 职务：" + job ;
    }
}

class Officer extends Employee{
    public String political;
    public String Otitle;

    public Officer(String id, String name, String sex, int age, String type, String political, String otitle) {
        super(id, name, sex, age, type);
        this.political = political;
        Otitle = otitle;
    }

    @Override
    public String toString() {
        return "行政人员：" +
                "编号:" + id  +
                ", 姓名：" + name +
                ", 性别：" + sex  +
                ", 年龄：" + age +
                ", 政治面貌：" + political +
                ", 职称：" + Otitle ;
    }

    public String getPolitical() {
        return political;
    }

    public void setPolitical(String political) {
        this.political = political;
    }

    public String getOtitle() {
        return Otitle;
    }

    public void setOtitle(String otitle) {
        Otitle = otitle;
    }
}

class TOfficer extends Teacher{
    public String  TOpolitical;

    public TOfficer(String id, String name, String sex, int age, String type, String department, String major, String title, String TOpolitical) {
        super(id, name, sex, age, type, department, major, title);
        this.TOpolitical = TOpolitical;
    }

    @Override
    public String toString() {
        return "兼职人员：" +
                "编号:" + id  +
                ", 姓名：" + name +
                ", 性别：" + sex  +
                ", 年龄：" + age +
                ", 所在系：" + department +
                ", 专业：" + major  +
                ", 职称：" + title  +
                ", 政治面貌：" + TOpolitical;
    }

    public String getTOpolitical() {
        return TOpolitical;
    }

    public void setTOpolitical(String TOpolitical) {
        this.TOpolitical = TOpolitical;
    }
}